/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package cl.zeke.pizzastore.vista.managedbeans;

import cl.zeke.pizzastore.wsclient.remoto.Persona;
import cl.zeke.pizzastore.wsclient.remoto.PersonaSoapServiceService;
import java.io.Serializable;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;

/**
 *
 * @author taller
 */
@Component
@Scope("view")
public class ConsumirSoapBean implements Serializable {
    
    private Persona persona;
    
    public void consumirSoap() {
        PersonaSoapServiceService service = new PersonaSoapServiceService();
        persona = service.getPersonaSoapServicePort().traerPorNombre("soap");
    }

    public Persona getPersona() {
        return persona;
    }

    public void setPersona(Persona persona) {
        this.persona = persona;
    }
    
}
